﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Configuration;

namespace PSE.Framework.Common.Security.Services.Configuration
{
    /// <summary>
    /// Classe de configuração relacionada a autenticação
    /// </summary>
    public class ServicesConfigurationSection : ConfigurationSection
    {
        [ConfigurationProperty("issuerAddress")]
        public string IssuerAddress
        {
            get
            {
                return (string)this["issuerAddress"];
            }
            set
            {
                this["issuerAddress"] = value;
            }
        }

        [ConfigurationProperty("criptographyLevel")]
        public CriptographyLevelType CriptographyLevel
        {
            get
            {
                return (CriptographyLevelType)this["criptographyLevel"];
            }
            set
            {
                this["criptographyLevel"] = value;
            }
        }


        [ConfigurationProperty("channelTimeout")]
        public int ChannelTimeout
        {
            get
            {
                return (int)this["channelTimeout"];
            }
            set
            {
                this["channelTimeout"] = value;
            }
        }
    }

    public enum CriptographyLevelType
    {
        Basic,
        Transport,
        Federated
    }
}
